﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace MattDotson.GlobalToolkit
{
    /// <summary>
    /// Interface for implementing a service locator.  This extensibilty point allows for consumers of the global toolkit 
    /// to utilize their own container or IoC implementation as the service locator.
    /// </summary>
    /// <remarks>
    /// Global Toolkit implements a very simple service locator.  It is recommended to use your own container or IoC implementation
    /// instead of Global Toolkit's implementation.
    /// </remarks>
    public interface IServiceLocator
    {
        /// <summary>
        /// Resolves an instance.
        /// </summary>
        /// <typeparam name="T"></typeparam>
        /// <returns></returns>
        [System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Design", "CA1004:GenericMethodsShouldProvideTypeParameter")]
        T Resolve<T>();
    }
}
